// Learn TypeScript:
//  - https://docs.cocos.com/creator/manual/en/scripting/typescript.html
// Learn Attribute:
//  - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
//  - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html

const { ccclass, property } = cc._decorator;

@ccclass
export default class ChuiziComp extends cc.Component {



    start() {
        this.showChuizi()
    }
    showChuizi() {
        // cc.Tween.stopAllByTarget(this.node)
        this.node.angle = -60
        cc.tween(this.node).by(0.3, { angle: 30 }).by(0.3, { angle: -30 }).call(() => {
            this.showChuizi()
        }).start()
    }
    // update (dt) {}
}
